 /* Copyright 2018 JDCLOUD.COM

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http:#www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.





Contact: 

NOTE: This class is auto generated by the jdcloud code generator program.
*/


#import <Foundation/Foundation.h>
#import <JDCloudOCSDKYunding/YundingModel.h>

@implementation VmImageOverview
-(id) initWithName:(NSString*) name
      platform:(NSString*)platform { 
     self.name = name;               
     self.platform = platform;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self platform])
    {
        [result setValue:[self platform] forKey:@"platform"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.name = [dictionary objectForKey:@"name"];
    self.platform = [dictionary objectForKey:@"platform"];
    return self;
}
 @end
@implementation Cluster
-(id) initWithId:(NSString*) idValue
      name:(NSString*)name
      dataCenter:(NSString*)dataCenter
      domain:(NSString*)domain
      connectionPort:(NSString*)connectionPort
      dbEngine:(NSString*)dbEngine
      dbVersion:(NSString*)dbVersion { 
     self.idValue = idValue;               
     self.name = name;               
     self.dataCenter = dataCenter;               
     self.domain = domain;               
     self.connectionPort = connectionPort;               
     self.dbEngine = dbEngine;               
     self.dbVersion = dbVersion;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self idValue])
    {
        [result setValue:[self idValue] forKey:@"id"];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self dataCenter])
    {
        [result setValue:[self dataCenter] forKey:@"dataCenter"];
    }
    if([self domain])
    {
        [result setValue:[self domain] forKey:@"domain"];
    }
    if([self connectionPort])
    {
        [result setValue:[self connectionPort] forKey:@"connectionPort"];
    }
    if([self dbEngine])
    {
        [result setValue:[self dbEngine] forKey:@"dbEngine"];
    }
    if([self dbVersion])
    {
        [result setValue:[self dbVersion] forKey:@"dbVersion"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.idValue = [dictionary objectForKey:@"id"];
    self.name = [dictionary objectForKey:@"name"];
    self.dataCenter = [dictionary objectForKey:@"dataCenter"];
    self.domain = [dictionary objectForKey:@"domain"];
    self.connectionPort = [dictionary objectForKey:@"connectionPort"];
    self.dbEngine = [dictionary objectForKey:@"dbEngine"];
    self.dbVersion = [dictionary objectForKey:@"dbVersion"];
    return self;
}
 @end
@implementation RdsInstance
-(id) initWithInstanceId:(NSString*) instanceId
      instanceName:(NSString*)instanceName
      instanceType:(NSString*)instanceType
      engine:(NSString*)engine
      engineVersion:(NSString*)engineVersion
      instanceClass:(NSString*)instanceClass
      instanceStorageGB:(NSNumber*)instanceStorageGB
      instanceCPU:(NSNumber*)instanceCPU
      instanceMemoryMB:(NSNumber*)instanceMemoryMB
      regionId:(NSString*)regionId
      azId:(NSArray<NSString*>*)azId
      vpcId:(NSString*)vpcId
      vpcName:(NSString*)vpcName
      subnetId:(NSString*)subnetId
      instanceStatus:(NSString*)instanceStatus
      createTime:(NSString*)createTime
      sourceInstanceId:(NSString*)sourceInstanceId { 
     self.instanceId = instanceId;               
     self.instanceName = instanceName;               
     self.instanceType = instanceType;               
     self.engine = engine;               
     self.engineVersion = engineVersion;               
     self.instanceClass = instanceClass;               
     self.instanceStorageGB = instanceStorageGB;               
     self.instanceCPU = instanceCPU;               
     self.instanceMemoryMB = instanceMemoryMB;               
     self.regionId = regionId;               
     self.azId = azId;               
     self.vpcId = vpcId;               
     self.vpcName = vpcName;               
     self.subnetId = subnetId;               
     self.instanceStatus = instanceStatus;               
     self.createTime = createTime;               
     self.sourceInstanceId = sourceInstanceId;               
    return self;
}

-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self instanceId])
    {
        [result setValue:[self instanceId] forKey:@"instanceId"];
    }
    if([self instanceName])
    {
        [result setValue:[self instanceName] forKey:@"instanceName"];
    }
    if([self instanceType])
    {
        [result setValue:[self instanceType] forKey:@"instanceType"];
    }
    if([self engine])
    {
        [result setValue:[self engine] forKey:@"engine"];
    }
    if([self engineVersion])
    {
        [result setValue:[self engineVersion] forKey:@"engineVersion"];
    }
    if([self instanceClass])
    {
        [result setValue:[self instanceClass] forKey:@"instanceClass"];
    }
    if([self instanceStorageGB])
    {
        [result setValue:[self instanceStorageGB] forKey:@"instanceStorageGB"];
    }
    if([self instanceCPU])
    {
        [result setValue:[self instanceCPU] forKey:@"instanceCPU"];
    }
    if([self instanceMemoryMB])
    {
        [result setValue:[self instanceMemoryMB] forKey:@"instanceMemoryMB"];
    }
    if([self regionId])
    {
        [result setValue:[self regionId] forKey:@"regionId"];
    }
    if([self azId])
    {
        [result setValue:[self azId] forKey:@"azId"];
    }
    if([self vpcId])
    {
        [result setValue:[self vpcId] forKey:@"vpcId"];
    }
    if([self vpcName])
    {
        [result setValue:[self vpcName] forKey:@"vpcName"];
    }
    if([self subnetId])
    {
        [result setValue:[self subnetId] forKey:@"subnetId"];
    }
    if([self instanceStatus])
    {
        [result setValue:[self instanceStatus] forKey:@"instanceStatus"];
    }
    if([self createTime])
    {
        [result setValue:[self createTime] forKey:@"createTime"];
    }
    if([self sourceInstanceId])
    {
        [result setValue:[self sourceInstanceId] forKey:@"sourceInstanceId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.instanceId = [dictionary objectForKey:@"instanceId"];
    self.instanceName = [dictionary objectForKey:@"instanceName"];
    self.instanceType = [dictionary objectForKey:@"instanceType"];
    self.engine = [dictionary objectForKey:@"engine"];
    self.engineVersion = [dictionary objectForKey:@"engineVersion"];
    self.instanceClass = [dictionary objectForKey:@"instanceClass"];
    self.instanceStorageGB = [dictionary objectForKey:@"instanceStorageGB"];
    self.instanceCPU = [dictionary objectForKey:@"instanceCPU"];
    self.instanceMemoryMB = [dictionary objectForKey:@"instanceMemoryMB"];
    self.regionId = [dictionary objectForKey:@"regionId"];
    self.azId = [dictionary objectForKey:@"azId"];
    self.vpcId = [dictionary objectForKey:@"vpcId"];
    self.vpcName = [dictionary objectForKey:@"vpcName"];
    self.subnetId = [dictionary objectForKey:@"subnetId"];
    self.instanceStatus = [dictionary objectForKey:@"instanceStatus"];
    self.createTime = [dictionary objectForKey:@"createTime"];
    self.sourceInstanceId = [dictionary objectForKey:@"sourceInstanceId"];
    return self;
}
 @end
 
 


